package com.qfedu.smart_community.entity;

import java.io.Serializable;

/**
 * 
 * @TableName meter_category
 */
public class MeterCategory implements Serializable {
    /**
     * 主键ID
     */
    private Integer id;

    /**
     * 类别代码
     */
    private String categoryCode;

    /**
     * 类别名称
     */
    private String categoryName;

    /**
     * 收费编码
     */
    private String chargeCode;

    /**
     * 收费名称
     */
    private String chargeName;

    private static final long serialVersionUID = 1L;

    /**
     * 主键ID
     */
    public Integer getId() {
        return id;
    }

    /**
     * 主键ID
     */
    public void setId(Integer id) {
        this.id = id;
    }

    /**
     * 类别代码
     */
    public String getCategoryCode() {
        return categoryCode;
    }

    /**
     * 类别代码
     */
    public void setCategoryCode(String categoryCode) {
        this.categoryCode = categoryCode;
    }

    /**
     * 类别名称
     */
    public String getCategoryName() {
        return categoryName;
    }

    /**
     * 类别名称
     */
    public void setCategoryName(String categoryName) {
        this.categoryName = categoryName;
    }

    /**
     * 收费编码
     */
    public String getChargeCode() {
        return chargeCode;
    }

    /**
     * 收费编码
     */
    public void setChargeCode(String chargeCode) {
        this.chargeCode = chargeCode;
    }

    /**
     * 收费名称
     */
    public String getChargeName() {
        return chargeName;
    }

    /**
     * 收费名称
     */
    public void setChargeName(String chargeName) {
        this.chargeName = chargeName;
    }

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        MeterCategory other = (MeterCategory) that;
        return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
            && (this.getCategoryCode() == null ? other.getCategoryCode() == null : this.getCategoryCode().equals(other.getCategoryCode()))
            && (this.getCategoryName() == null ? other.getCategoryName() == null : this.getCategoryName().equals(other.getCategoryName()))
            && (this.getChargeCode() == null ? other.getChargeCode() == null : this.getChargeCode().equals(other.getChargeCode()))
            && (this.getChargeName() == null ? other.getChargeName() == null : this.getChargeName().equals(other.getChargeName()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
        result = prime * result + ((getCategoryCode() == null) ? 0 : getCategoryCode().hashCode());
        result = prime * result + ((getCategoryName() == null) ? 0 : getCategoryName().hashCode());
        result = prime * result + ((getChargeCode() == null) ? 0 : getChargeCode().hashCode());
        result = prime * result + ((getChargeName() == null) ? 0 : getChargeName().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", id=").append(id);
        sb.append(", categoryCode=").append(categoryCode);
        sb.append(", categoryName=").append(categoryName);
        sb.append(", chargeCode=").append(chargeCode);
        sb.append(", chargeName=").append(chargeName);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}